HAL Initialization Interface.
More...
|
| KER_BOOL | hal_init (KER_CTX_INIT_PARAM const KER_VOID *pConfigID, KER_INT16U usConfigIDLen, const KER_CHAR *pchKernelModuleList, KER_INT16U usKernelModuleListLen) |
| | Performs HAL initialization. More...
|
| |
| KER_BOOL | hal_deinit (KER_CTX_SINGLE_PARAM) |
| | Performs HAL de-initialization. More...
|
| |
| KER_BOOL | hal_start_tran (KER_CTX_SINGLE_PARAM) |
| | Informs HAL about transaction start (to open new log, create new STAN, etc...) More...
|
| |
| KER_BOOL | hal_end_tran (KER_CTX_SINGLE_PARAM) |
| | Informs HAL about transaction end (to close curr log, etc...) More...
|
| |
| KER_BOOL | hal_calc_checksum (KER_CTX_PARAM KER_BYTE btType, KER_BYTE *pbtCheckSum, KER_INT16U *pusCheckSumLen, KER_INT16U usMaxSize) |
| | Pass checksums to the kernel. More...
|
| |
| KER_BOOL | hal_calc_checksum_ex (KER_CTX_PARAM KER_BYTE btType, const KER_CHAR *pchKernelModuleList, KER_INT16U usKernelModuleListLen, KER_BYTE *pbtCheckSum, KER_INT16U *pusCheckSumLen, KER_INT16U usMaxSize) |
| | Pass checksums to the kernel. More...
|
| |
| KER_BOOL | hal_register_callback (KER_CTX_PARAM KER_INT16U usCallbackType, KER_VOID *pCallback) |
| | Register callback to be used by HAL. At the moment use it only for backward compatibility to provide L1 interface as callback. More...
|
| |
| KER_BOOL | hal_notify (KER_CTX_PARAM KER_INT16U usNotifyType, const KER_VOID *pNotifyData, KER_INT16U usNotifyDataLen) |
| | Notifies HAL about some specific event. More...
|
| |
| KER_BOOL | hal_online_check (KER_CTX_SINGLE_PARAM) |
| | Checks HAL for unable to go online condition (for AmEx C-4). More...
|
| |
| #define | KER_HAL_CALLBACK_HANDLE 0x00 |
| |
| #define | KER_HAL_CALLBACK_EMVL1_RESET_CARD 0x10 |
| |
| #define | KER_HAL_CALLBACK_EMVL1_EXCH_APDU 0x11 |
| |
| #define | KER_HAL_CALLBACK_EMVL1_IFD_SERIAL 0x12 |
| |
| #define | KER_HAL_CALLBACK_CV_CHECK_CUST_CVM_CONDITION 0x20 |
| |
| #define | KER_HAL_CALLBACK_CV_CHECK_CUST_CVM 0x21 |
| |
| #define | KER_HAL_NOTIFY_SELECTED_AID 0x01 |
| |
| #define | KER_HAL_NOTIFY_SELECTED_KERNEL_ID 0x02 |
| |
HAL Initialization Interface.
This functions should be implemented by terminal application
◆ KER_HAL_CALLBACK_CV_CHECK_CUST_CVM
| #define KER_HAL_CALLBACK_CV_CHECK_CUST_CVM 0x21 |
◆ KER_HAL_CALLBACK_CV_CHECK_CUST_CVM_CONDITION
| #define KER_HAL_CALLBACK_CV_CHECK_CUST_CVM_CONDITION 0x20 |
◆ KER_HAL_CALLBACK_EMVL1_EXCH_APDU
| #define KER_HAL_CALLBACK_EMVL1_EXCH_APDU 0x11 |
◆ KER_HAL_CALLBACK_EMVL1_IFD_SERIAL
| #define KER_HAL_CALLBACK_EMVL1_IFD_SERIAL 0x12 |
◆ KER_HAL_CALLBACK_EMVL1_RESET_CARD
| #define KER_HAL_CALLBACK_EMVL1_RESET_CARD 0x10 |
◆ KER_HAL_CALLBACK_HANDLE
| #define KER_HAL_CALLBACK_HANDLE 0x00 |
Set callback handle to be passed to other callbacks
◆ KER_HAL_DEINIT
◆ KER_HAL_END_TRAN
◆ KER_HAL_INIT
| #define KER_HAL_INIT |
( |
|
ConfigID, |
|
|
|
ConfigIDLen, |
|
|
|
KernelBinary, |
|
|
|
KernelBinaryLen |
|
) |
| hal_init(KER_CTX_INIT ConfigID, ConfigIDLen, KernelBinary, KernelBinaryLen) |
◆ KER_HAL_NOTIFY_SELECTED_AID
| #define KER_HAL_NOTIFY_SELECTED_AID 0x01 |
◆ KER_HAL_NOTIFY_SELECTED_KERNEL_ID
| #define KER_HAL_NOTIFY_SELECTED_KERNEL_ID 0x02 |
Kernel selected event, pNotifyData contains KER_INT16U with Kernel ID
◆ KER_HAL_START_TRAN
◆ hal_calc_checksum()
Pass checksums to the kernel.
- Parameters
-
| [in] | btType | Requested checksum type: 0x00 - Kernel checksum; 0x01 - Configuration checksum; 0x02 - Full Configuration checksum |
| [out] | pbtCheckSum | Buffer to obtain claculated checksum |
| [out] | pusCheckSumLen | Value to obtain claculated checksum length |
| [in] | usMaxSize | Size of pchCheckSum Buffer |
- Returns
- KER_TRUE Success.
-
KER_FALSE Failure.
◆ hal_calc_checksum_ex()
Pass checksums to the kernel.
- Parameters
-
| [in] | btType | Requested checksum type: 0x00 - Kernel checksum; 0x01 - Configuration checksum; 0x02 - Full Configuration checksum |
| [in] | pchKernelModuleList | Buffer with a list of module names to include in kernel checksum, each terminated with a zero character, and an extra zero character in the end (optional) |
| [in] | usKernelModuleListLen | pchKernelModuleList buffer length |
| [out] | pbtCheckSum | Buffer to obtain claculated checksum |
| [out] | pusCheckSumLen | Value to obtain claculated checksum length |
| [in] | usMaxSize | Size of pchCheckSum Buffer |
- Returns
- KER_TRUE Success.
-
KER_FALSE Failure.
◆ hal_deinit()
◆ hal_end_tran()
Informs HAL about transaction end (to close curr log, etc...)
- Returns
- KER_TRUE Success.
-
KER_FALSE Failure.
◆ hal_init()
Performs HAL initialization.
- Parameters
-
| [in] | pConfigID | Buffer with configuration ID obtained from Terminal Application (in HAL recognized format) |
| [in] | usConfigIDLen | pConfigID buffer length |
| [in] | pchKernelModuleList | Buffer with a list of module names to include in kernel checksum, each terminated with a zero character, and an extra zero character in the end |
| [in] | usKernelModuleListLen | pchKernelModuleList buffer length |
- Returns
- KER_TRUE Success.
-
KER_FALSE Failure.
Terminal Application should obtain context data reference (if context usage configured) and pass it to all other kernel functions
- Warning
- Allocated context should be released by hal_deinit.
◆ hal_notify()
◆ hal_online_check()
Checks HAL for unable to go online condition (for AmEx C-4).
- Returns
- KER_TRUE Online available or Online state is unknown (default).
-
KER_FALSE Unable to go online condition.
◆ hal_register_callback()
Register callback to be used by HAL. At the moment use it only for backward compatibility to provide L1 interface as callback.
- Parameters
-
- Returns
- KER_TRUE Success.
-
KER_FALSE Failure. Execution failed due to invalid param or reader error.
- Warning
- Deprecated function. Use it only for backward compatibility.
◆ hal_start_tran()
Informs HAL about transaction start (to open new log, create new STAN, etc...)
- Returns
- KER_TRUE Success.
-
KER_FALSE Failure.